<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>测试</title>
    <script src="js\node_modules\jquery\dist\jquery.js"></script>

</head>
<body>
<div class="header-nav">
    <input id="firstPageBtn" type="button" class="clickbutton" value="首页"/>
    <input id="prevPageBtn" type="button" class="clickbutton" value="上页"/>
    <input id="nextPageBtn" type="button" class="clickbutton" value="下页"/>
    <input id="lastPageBtn" type="button" class="clickbutton" value="末页"/>
    跳到第<input type="text" id="pageNum" value="2" class="nav-number"/>页
    <input id="jumpBtn" type="button" class="clickbutton" value="跳转"/>
</div>
<div class="header-info">
    共<span class="info-number">5</span>条结果，
    分成<span class="info-number">4</span>页显示，
    当前第<span id="currentNum" class="info-number">1</span>页
</div>
<script>
    let pageNum = 1;
    if (pageNum==1){
        $("#prevPageBtn").css("display","none");
    }
    console.log($("#pageNum")[0].value);
    $("#currentNum").text(pageNum+1);
    console.log($("#pageNum"));
    const pageNumInput = document.querySelector('#pageNum');
    console.log(pageNumInput);
    const jumpBtn = document.querySelector('#jumpBtn');
    jumpBtn.addEventListener('click', function() {
        const pageNum = pageNumInput.value;
        console.log(pageNum);
    });
</script>
</body>
</html>